package org.management.system.entity;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.management.base.BaseEntity;

import javax.persistence.Column;
import javax.persistence.Table;
import javax.validation.constraints.NotEmpty;

/**
 * 功能描述
 * 角色模块
 * @author jiangyan
 * @date 2019/03/14
 * @description
 * @project management
 */
@Data
@ApiModel(value="角色")
@EqualsAndHashCode(callSuper = true)
@Table(name = "sys_role")
public class RoleEntity extends BaseEntity {
    /**
     * 角色名称
     */
    @Column(name = "ROLE_NAME")
    @NotEmpty(message = "角色名称不能为空")
    @ApiModelProperty(value = "角色名称",name = "roleName", required = true)
    private String roleName;

    /**
     * 是否启用 1启用 0 禁用
     */
    @Column(name = "IS_OPEN")
    @ApiModelProperty(value = "是否启用 1启用 0 禁用",name = "isOpen")
    private Boolean isOpen;

    @Column(name = "LEVEL")
    @ApiModelProperty(value = "LEVEL",name = "level")
    private Integer level;
}